package org.open.cobertura.cli;

import org.open.cobertura.cli.util.ArgsUtil;

public class CommandLineBuilder {
    private String host;
    private int port;
    private String source;
    private String classes;
    public CommandLineBuilder(String []args) {
        String hostStr=ArgsUtil.getParam(args,1+1);
        String []hosts=hostStr.split(":");
        this.host=hosts[0];
        this.port=Integer.parseInt(hosts[1]);
        this.source=ArgsUtil.getParam(args,3+1);
        this.classes=ArgsUtil.getParam(args,5+1);
    }

    public String getHost() {
        return host;
    }

    public void setHost(String host) {
        this.host = host;
    }

    public int getPort() {
        return port;
    }

    public void setPort(int port) {
        this.port = port;
    }

    public String getSource() {
        return source;
    }

    public void setSource(String source) {
        this.source = source;
    }

    public String getClasses() {
        return classes;
    }

    public void setClasses(String classes) {
        this.classes = classes;
    }
}
